home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat3 / standard / hypot.z / hypot
Encoding:
Text File  |  2002-10-03  |  4.6 KB  |  83 lines

  1. HYPOT(3M)                                              Last changed: 2-2-99
  2.  
  3.  
  4. NNAAMMEE
  5.      hhyyppoott, hhyyppoottff, ffhhyyppoott, hhyyppoottll, ccaabbss, ccaabbssff, ffccaabbss, ccaabbssll - Euclidean
  6.      distance, complex absolute value
  7.  
  8. SSYYNNOOPPSSIISS
  9.      ##iinncclluuddee <<mmaatthh..hh>>
  10.  
  11.      ddoouubbllee hhyyppoott ((ddoouubbllee _x,, ddoouubbllee _y));;
  12.      ffllooaatt ffhhyyppoott ((ffllooaatt _x,, ffllooaatt _y));;
  13.      ffllooaatt hhyyppoottff ((ffllooaatt _x,, ffllooaatt _y));;
  14.      lloonngg ddoouubbllee hhyyppoottll ((lloonngg ddoouubbllee _x,, lloonngg ddoouubbllee _y));;
  15.  
  16.      ddoouubbllee ccaabbss ((ssttrruucctt {{ ddoouubbllee _a,,_b;; }} _z));;
  17.      ffllooaatt ffccaabbss ((ssttrruucctt {{ ffllooaatt _a,,_b;; }} _z));;
  18.      ffllooaatt ccaabbssff ((ssttrruucctt {{ ffllooaatt _a,,_b;; }} _z));;
  19.      lloonngg ddoouubbllee ccaabbssll ((ssttrruucctt {{ lloonngg ddoouubbllee _a,,_b;; }} _z));;
  20.  
  21. IIMMPPLLEEMMEENNTTAATTIIOONN
  22.      IRIX systems
  23.  
  24. DDEESSCCRRIIPPTTIIOONN
  25.      hhyyppoott((_x,,_y)), ffhhyyppoott((_x,,_y)), hhyyppoottff((_x,,_y)), hhyyppoottll((_x,,_y)), ccaabbss((_x,,_y)),
  26.      ffccaabbss((_x,,_y)), ccaabbssff((_x,,_y)), and ccaabbssll((_x,,_y)) return ssqqrrtt((xx**xx ++ yy**yy)) computed
  27.      in such a way that overflow will not happen, and underflow occurs only
  28.      if the final result deserves it.
  29.  
  30.      ffhhyyppoott, hhyyppoottff, ffccaabbss, and ccaabbssff are the same functions as hhyyppoott and
  31.      ccaabbss but for the float data type.
  32.  
  33.      hhyyppoottll, and ccaabbssll are the same functions as hhyyppoott and ccaabbss but for the
  34.      long double data type.
  35.  
  36. NNOOTTEESS
  37.      Long double operations on this system are only supported in _r_o_u_n_d-_t_o-
  38.      _n_e_a_r_e_s_t rounding mode (the default). The system must be in round-to-
  39.      nearest rounding mode when calling any of the long double functions,
  40.      or incorrect answers will result.
  41.  
  42.      Users concerned with portability to other computer systems should note
  43.      that the long double and float versions of these functions are
  44.      optional according to the ANSI C Programming Language Specification
  45.      ISO/IEC 9899 : 1990 (E).
  46.  
  47.      Long double functions have been renamed to be compliant with the
  48.      ANSI-C standard; however, to be backward compatible, they may still be
  49.      called with the double precision function name prefixed with a qq.
  50.  
  51.      hhyyppoott and ccaabbss are not ANSI-C functions.  If you compile with the
  52.      --aannssii option, you must supply your own prototypes for these functions
  53.      or you get incorrect results.  (See the prototypes defined in
  54.      //uussrr//iinncclluuddee//mmaatthh..hh).
  55.  
  56.    EErrrroorrss
  57.      Below 0.97 ULPs.  Consequently hhyyppoott((55..00,,1122..00)) == 1133..00 exactly; in
  58.      general, hhyyppoott and ccaabbss return an integer whenever an integer might be
  59.      expected.
  60.  
  61. RREETTUURRNN VVAALLUUEESS
  62.      Functions in the standard math library lliibbmm..aa are referred to as --llmm
  63.      versions. Those in lliibbmmxx..aa are referred to as --llmmxx versions. Those in
  64.      the the BSD math library lliibbmm4433..aa are referred to as --llmm4433 versions.
  65.  
  66.      The --llmm and --llmmxx versions always return the default Quiet NaN and set
  67.      eerrrrnnoo to EDOM when a NaN is used as an argument.  A NaN argument
  68.      causes the --llmm4433 versions of the hhyyppoott functions to return the same
  69.      NaN, unless the other argument is HHUUGGEE__VVAALL, in which case HHUUGGEE__VVAALL is
  70.      returned.
  71.  
  72.      The --llmm4433 versions never set eerrrrnnoo. The value of HHUUGGEE__VVAALL is IEEE
  73.      Infinity.
  74.  
  75.      When the correct value would overflow, the hhyyppoott functions return
  76.      HHUUGGEE__VVAALL.  The --llmm and --llmmxx versions also set eerrrrnnoo to ERANGE. See
  77.      mmaatthheerrrr(3M) for a description of error handling for --llmmxx functions.
  78.  
  79. SSEEEE AALLSSOO
  80.      mmaatthh(3M), ssqqrrtt(3M), mmaatthheerrrr(3M)
  81.  
  82.      This man page is available only online.
  83.